From 58ae7777f2bc2910ae57900e33a20fc7ef1e3b7f Mon Sep 17 00:00:00 2001 From: "kaf24@scramble.cl.cam.ac.uk" Date: Mon, 15 Mar 2004 15:54:37 +0000 Subject: [PATCH] bitkeeper revision 1.799 (4055d1bd4oP9eNVVeSlvvnj5F9We2w) utils.c, Xc.c: Fix building with Python 2.2. --- tools/xc/py/Xc.c | 5 +++++ tools/xend/lib/utils.c | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/tools/xc/py/Xc.c b/tools/xc/py/Xc.c index 124942bbb0..8ed16ee505 100644 --- a/tools/xc/py/Xc.c +++ b/tools/xc/py/Xc.c @@ -7,6 +7,11 @@ #include #include +/* Needed for Python versions earlier than 2.3. */ +#ifndef PyMODINIT_FUNC +#define PyMODINIT_FUNC DL_EXPORT(void) +#endif + static PyObject *xc_error, *zero; typedef struct { diff --git a/tools/xend/lib/utils.c b/tools/xend/lib/utils.c index de832a1761..c5954043d6 100644 --- a/tools/xend/lib/utils.c +++ b/tools/xend/lib/utils.c @@ -23,6 +23,11 @@ #include #include +/* Needed for Python versions earlier than 2.3. */ +#ifndef PyMODINIT_FUNC +#define PyMODINIT_FUNC DL_EXPORT(void) +#endif + /* NB. The following should be kept in sync with the kernel's evtchn driver. */ #define EVTCHN_DEV_NAME "/dev/xen/evtchn" #define EVTCHN_DEV_MAJOR 10 -- 2.30.2